DOpus desktoppopup

back to section start!

   New for Magellan II

  Supposing in your nice, new script you want to give the user a choice when
they drop a file on the Desktop of either; creating a left-out or either
copying or moving to the Desktop.

  The  dopus desktoppopup  command will allow you to popup the Desktop menu,
letting you choose any one of these, the value of the choice will be returned
in  RC .

  The options can be limited by adding a flag to the command, so you could,
for example, limit the options to just 'Create left-out'.  The value of the
flags can be added together to disable more than one options.

  Flag      Option        Result Code
   2     Create Left-out      1
   4     Copy to Desktop      2
   8     Move to Desktop      3

  So to disable the Copy and Move to Desktop options, you would specify a
flag of 12.

  Example:


 /* DopusDesktoppopup.dopus5 */ 
options results
address 'DOPUS.1'
dopus front
text = 'The mouse will need to be over the'||lf||,
       'Desktop, not a lister or button bank.'
dopus request '"'text'" OK'
address command wait 1
dopus desktoppopup 4
text = 'Nothing chosen'
if rc = 1 then text = 'Create Left-out'
if rc = 3 the ntext = 'Move to Desktop'
dopus request '"'text'" OK'
dopus back
exit

DOpus PLUS - giving you that bit extra...